package com.amumu.drama.portal.modules.member.dto.req;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;
import java.io.Serializable;

/**
 * @author sunzhuang
 * @date 2024/5/24 15:56
 * @slogan 天下风云出我辈, 一入代码岁月催
 * @desc todo
 */
@Data
@ApiModel("实名认证")
public class IdCardVerifyReq implements Serializable {

    @ApiModelProperty("姓名")
    @NotBlank(message = "姓名不能为空")
    private String realName;

    @ApiModelProperty("身份证号")
    @NotBlank(message = "身份证号不能为空")
    @Pattern(regexp = "^[1-9]\\d{5}(18|19|([23]\\d))\\d{2}((0[1-9])|(10|11|12))(([0-2][1-9])|10|20|30|31)\\d{3}[0-9Xx]$", message = "身份证号格式不正确")
    private String idCard;
}
